package com.yonyou.pmclouds.basecom.consts;

import java.util.HashMap;
import java.util.Map;

public class BillTypeConst4NCC {

    /**
     * 工作联系单单据类型
     */
    public static String WORKCONNECT_BILLTYPE = "4D90";
    /**
     * 问题记录单单据类型
     */
    public static String PROBLEMLOG_BILLTYPE = "4D70";
    /**
     * 工序报验单据类型
     */
    public static String PROCEDUREINSPECT_BILLTYPE = "4D91";
    /**
     * 平行检验单据类型
     */
    public static String PARALLEL_INSPECTION_BILLTYPE = "4D88-03";
    /**
     * 旁站记录单据类型
     */
    public static String SIDE_INSPECTION_BILLTYPE = "4D88-02";
    /**
     * 巡查记录单据类型
     */
    public static String PATROL_BILLTYPE = "4D88-01";

    /**
     * 施工记录单据类型
     */
    public static String CONSTRUCTIONLOG_BILLTYPE = "4D88-04";
    /**
     * 施工日志单据类型
     */
    public static String CONSTRUCTION_DIARY_BILLTYPE = "4D76";

    /**
     * 安全整改
     */
    public static String SAFETY_RECTIFICATION_BILLTYPE = "4D93";
    /**
     * 开工报告
     */
    public static String WORKSTART_BILLTYPE="4D23";
    /**
     * 停工单
     */
    public static String WORKSTOP_BILLTYPE="4D28";
    /**
     * 复工单
     */
    public static String REPEATWORK_BILLTYPE="4D29";

    /**
     * 阶段验收
     */
    public static String STAGECHECK_BILLTYPE="4D36-01";


    /**
     * 综合验收
     */
    public static String PROJECTCHECK_BILLTYPE="4D36-06";


    private static Map<String,String> pmcToNCCMap = new HashMap<>();

    /**
     * 获取友工程单据类型和NCC单据类型的对应关系
     *
     * @return
     */
    public static Map<String,String> getPMCToNCCMap(){

        if( pmcToNCCMap.size() > 0)
            return pmcToNCCMap;

        pmcToNCCMap.put(BillTypeConst.WORKCONNECT_BILLTYPE, BillTypeConst4NCC.WORKCONNECT_BILLTYPE);
        pmcToNCCMap.put(BillTypeConst.PROBLEMLOG_BILLTYPE, BillTypeConst4NCC.PROBLEMLOG_BILLTYPE);
        pmcToNCCMap.put(BillTypeConst.WORKSTART_BILLTYPE, BillTypeConst4NCC.WORKSTART_BILLTYPE);
        pmcToNCCMap.put(BillTypeConst.PROCEDUREINSPECT_BILLTYPE, BillTypeConst4NCC.PROCEDUREINSPECT_BILLTYPE);
        pmcToNCCMap.put(BillTypeConst.CONSTRUCTIONLOG_BILLTYPE, BillTypeConst4NCC.CONSTRUCTIONLOG_BILLTYPE);
        pmcToNCCMap.put(BillTypeConst.PARALLEL_INSPECTION_BILLTYPE, BillTypeConst4NCC.PARALLEL_INSPECTION_BILLTYPE);
        pmcToNCCMap.put(BillTypeConst.SIDE_INSPECTION_BILLTYPE, BillTypeConst4NCC.SIDE_INSPECTION_BILLTYPE);
        pmcToNCCMap.put(BillTypeConst.CONSTRUCTION_DIARY_BILLTYPE, BillTypeConst4NCC.CONSTRUCTION_DIARY_BILLTYPE);
        pmcToNCCMap.put(BillTypeConst.SAFETY_RECTIFICATION_BILLTYPE, BillTypeConst4NCC.SAFETY_RECTIFICATION_BILLTYPE);
        pmcToNCCMap.put(BillTypeConst.PATROL_BILLTYPE, BillTypeConst4NCC.PATROL_BILLTYPE);
        pmcToNCCMap.put(BillTypeConst.WORKSTOP_BILLTYPE, BillTypeConst4NCC.WORKSTOP_BILLTYPE);
        pmcToNCCMap.put(BillTypeConst.REPEATWORK_BILLTYPE, BillTypeConst4NCC.REPEATWORK_BILLTYPE);
        pmcToNCCMap.put(BillTypeConst.STAGECHECK_BILLTYPE,BillTypeConst4NCC.STAGECHECK_BILLTYPE);
        pmcToNCCMap.put(BillTypeConst.COMPREHENSIVE_ACCEPTANCE_BILLTYPE,BillTypeConst4NCC.PROJECTCHECK_BILLTYPE);

        return pmcToNCCMap;

    }

    private static Map<String,String> nccToPMCMap = new HashMap<>();

    /**
     * 获取NCC单据类型和友工程单据类型的对应关系
     *
     * @return
     */
    public static Map<String,String> getNccToPMCMap(){

        if( nccToPMCMap.size() > 0)
            return nccToPMCMap;

        nccToPMCMap.put(BillTypeConst4NCC.WORKCONNECT_BILLTYPE,BillTypeConst.WORKCONNECT_BILLTYPE);
        nccToPMCMap.put(BillTypeConst4NCC.PROBLEMLOG_BILLTYPE,BillTypeConst.PROBLEMLOG_BILLTYPE);
        nccToPMCMap.put(BillTypeConst4NCC.WORKSTART_BILLTYPE,BillTypeConst.WORKSTART_BILLTYPE);
        nccToPMCMap.put(BillTypeConst4NCC.PROCEDUREINSPECT_BILLTYPE,BillTypeConst.PROCEDUREINSPECT_BILLTYPE);
        nccToPMCMap.put(BillTypeConst4NCC.CONSTRUCTIONLOG_BILLTYPE,BillTypeConst.CONSTRUCTIONLOG_BILLTYPE );
        nccToPMCMap.put(BillTypeConst4NCC.PARALLEL_INSPECTION_BILLTYPE,BillTypeConst.PARALLEL_INSPECTION_BILLTYPE );
        nccToPMCMap.put(BillTypeConst4NCC.SIDE_INSPECTION_BILLTYPE,BillTypeConst.SIDE_INSPECTION_BILLTYPE);
        nccToPMCMap.put(BillTypeConst4NCC.CONSTRUCTION_DIARY_BILLTYPE,BillTypeConst.CONSTRUCTION_DIARY_BILLTYPE);
        nccToPMCMap.put(BillTypeConst4NCC.WORKSTOP_BILLTYPE,BillTypeConst.WORKSTOP_BILLTYPE);
        pmcToNCCMap.put(BillTypeConst4NCC.REPEATWORK_BILLTYPE, BillTypeConst.REPEATWORK_BILLTYPE);
        nccToPMCMap.put(BillTypeConst4NCC.STAGECHECK_BILLTYPE,BillTypeConst.STAGECHECK_BILLTYPE);
        nccToPMCMap.put(BillTypeConst4NCC.PATROL_BILLTYPE, BillTypeConst.PATROL_BILLTYPE);
        nccToPMCMap.put(BillTypeConst4NCC.SAFETY_RECTIFICATION_BILLTYPE, BillTypeConst.SAFETY_RECTIFICATION_BILLTYPE);
        nccToPMCMap.put(BillTypeConst4NCC.PROJECTCHECK_BILLTYPE,BillTypeConst.COMPREHENSIVE_ACCEPTANCE_BILLTYPE);
        return nccToPMCMap;

    }


    private static Map<String,String> pmcNameMap = new HashMap<>();

    /**
     * 获取NCC单据类型和友工程单据类型的对应关系
     *
     * @return
     */
    public static Map<String,String> getPmcNameMap(){

        if( pmcNameMap.size() > 0)
            return pmcNameMap;

        pmcNameMap.put(BillTypeConst.WORKCONNECT_BILLTYPE,"工作联系");
        pmcNameMap.put(BillTypeConst.PROBLEMLOG_BILLTYPE,"质量问题");
        pmcNameMap.put(BillTypeConst.WORKSTART_BILLTYPE,"开工报告");
        pmcNameMap.put(BillTypeConst.PROCEDUREINSPECT_BILLTYPE,"工序报验");
        pmcNameMap.put(BillTypeConst.CONSTRUCTIONLOG_BILLTYPE,"施工记录" );
        pmcNameMap.put(BillTypeConst.PARALLEL_INSPECTION_BILLTYPE,"平行检验" );
        pmcNameMap.put(BillTypeConst.SIDE_INSPECTION_BILLTYPE,"旁站记录");
        pmcNameMap.put(BillTypeConst.CONSTRUCTION_DIARY_BILLTYPE,"施工日志");
        pmcNameMap.put(BillTypeConst.WORKSTOP_BILLTYPE,"停工单");
        pmcNameMap.put(BillTypeConst.REPEATWORK_BILLTYPE,"复工单");
        pmcNameMap.put(BillTypeConst.STAGECHECK_BILLTYPE,"阶段验收");
        pmcNameMap.put(BillTypeConst.PATROL_BILLTYPE,"巡查记录");
        pmcNameMap.put(BillTypeConst.SAFETY_RECTIFICATION_BILLTYPE, "安全整改");
        pmcNameMap.put(BillTypeConst.COMPREHENSIVE_ACCEPTANCE_BILLTYPE, "综合验收");

        return pmcNameMap;

    }

}
